package cn.zhz.service.devuser;

import cn.zhz.dao.devuser.DevUserMapper;
import cn.zhz.pojo.DevUser;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

@Service
public class DevUserServiceImpl implements DevUserService {
    @Resource
    private DevUserMapper mapper;
    @Override
    public DevUser login(String devCode, String password) {
        DevUser devUser =null;
        devUser = mapper.getLoginUser(devCode);
        if(devUser!=null){
            if(!devUser.getDevPassword().equals(password)){
                devUser=null;
            }
        }
        return devUser;
    }
}
